﻿using System;
using System.Collections.Generic;
using System.Text;

namespace BaseSimpleAPI.ActionResult
{
    public class NotFoundResult : IActionResult
    {
        public byte[] GetRespondData()
        {
            // 修剪多余的响应头
            ResponseHeaderHelper.GetInstance().TrimResponseHeader("ContentType");

            // 补全响应头
            ResponseHeaderHelper.GetInstance().CompletionResponseHeader(new Dictionary<string, string>
            {
                { "ResponseEncoding", "UTF-8" },
                { "ContentType", "null" },
                { "StatusCode", "404" },
            });

            return ActionResultHelper.GetResponseData(null);
        }
    }
}
